import { View } from "@tarojs/components"
import ChatItem, { IChat } from "./ChatItem"



export interface ChatListProps {
    list: IChat[]
}

const ChatList = (props: ChatListProps) => {
    const { list } = props
  return (
    <View>
    
        {
            list.map(item => <ChatItem key={item.id} { ...item }/>)
        }
  
    </View>
  )
}

export default ChatList